//
//  MyTeamTableViewCell.swift
//  AreaChainblock
//
//  Created by 赵佟越 on 2018/9/28.
//  Copyright © 2018年 zhaotongyue. All rights reserved.
//

import UIKit
import HexColors

class MyTeamTableViewCell: UITableViewCell
    
{
    var titleLab:UILabel?
    var detailLable:UILabel?
    var mybackView:UIView?
    var coverImageView:UIImageView?
    var desLab:UILabel?
    var priceLab:UILabel?
    required init?(coder aDecoder: NSCoder) {
        super.init(coder: aDecoder)
        
        
    }
    
    override var frame:CGRect{
        didSet {
            var newFrame = frame
            newFrame.origin.x += 20/2
            newFrame.size.width -= 20
            newFrame.origin.y += 0
            newFrame.size.height -= 0
            super.frame = newFrame
        }
    }
    
    
    override init(style: UITableViewCellStyle, reuseIdentifier: String?) {
        
        super.init(style: style, reuseIdentifier: reuseIdentifier)
        
        self.lauoutUI()
        
    }
    
    func lauoutUI()  {
        //    self.backgroundColor = UIColor.clear
        
        
        
        titleLab = UILabel(frame:CGRect(x:15,y:5,width:kScreenWidth - 50,height:30))
        self.addSubview(titleLab!)
        titleLab?.font = UIFont.systemFont(ofSize: 16)
        priceLab = UILabel()
        priceLab?.textAlignment = .right
        priceLab?.font = UIFont.systemFont(ofSize: 16)
        self.addSubview(priceLab!)
        priceLab?.snp.makeConstraints({ (make) in
            make.right.equalTo(self).offset(-35)
            make.centerY.equalTo(self)
            make.size.equalTo(CGSize(width: 200, height: 30))
        })
        priceLab?.textColor =  UIColor("909090")
        detailLable = UILabel(frame:CGRect(x:15,y:35,width:kScreenWidth - 50,height:30))
        self.addSubview(detailLable!)
        detailLable?.font = UIFont.systemFont(ofSize: 16)
        detailLable?.textColor =  UIColor("909090")
        
       
        
    }
    
    
    
    
    
    
    
    
    override func awakeFromNib() {
        
        super.awakeFromNib()
        
        // Initialization code
        
    }
    
    override func setSelected(_ selected: Bool, animated: Bool) {
        
        super.setSelected(selected, animated: animated)
        
        
        
        // Configure the view for the selected state
        
    }
    
}
